/*
 * @Author: linzaifei 1609781601@qq.com
 * @Date: 2025-08-07 09:16:10
 * @LastEditors: linzaifei 1609781601@qq.com
 * @LastEditTime: 2025-08-07 09:57:33
 * @FilePath: /vue-cesium-electron/src/main.ts
 * @Description: 这是默认设置,请设置`customMade`, 打开koroFileHeader查看配置 进行设置: https://github.com/OBKoro1/koro1FileHeader/wiki/%E9%85%8D%E7%BD%AE
 */
import './style.css'
import './assets/base.css'

import { createApp } from 'vue'

import App from './App.vue'
import ElementPlus from 'element-plus'
import 'element-plus/dist/index.css'
import './assets/element-theme.scss'

import piniaPluginPersistedstate from 'pinia-plugin-persistedstate'
import router from './router'
import { createPinia } from 'pinia'
import VueCesium from 'vue-cesium'
import 'vue-cesium/dist/index.css'

const pinia = createPinia()
pinia.use(piniaPluginPersistedstate)
const app = createApp(App)
app.use(ElementPlus).use(pinia).use(router)


app.use(VueCesium, {
  cesiumPath:'https://earthsdk.com/v/last/XbsjEarth/XbsjEarth.js',
  accessToken: 'eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJqdGkiOiJlZmUzZjYyNi02YzE1LTRiMjAtYmJhMC00ODZmYTgwY2I0MmEiLCJpZCI6MzAyMjc4LCJpYXQiOjE3NDcxODk2MzN9.EDmfsllbSlbcVd_nl88r9kVxyWwnbHujeNH98JI9_N0',
})

app.mount('#app').$nextTick(() => {
  // Use contextBridge
  window.ipcRenderer.on('main-process-message', (_event, message) => {
    console.log(message)
  })
})
